package com.zuipin.service;

import java.math.BigDecimal;
import java.text.ParseException;
import java.util.List;

import com.zuipin.entity.OrderDetail;
import com.zuipin.entity.OrderInfo;
import com.zuipin.entity.PayOrder;
import com.zuipin.framework.exception.CustomException;
import com.zuipin.framework.result.Result;
import com.zuipin.vo.ModityOrderUseStore;
import com.zuipin.vo.PayOrderVo;

public interface IPayOrderService {
	public Result updateToPay(Long payId, Long sysUserId, Result res, String payMethod) throws CustomException;
	
	public Result submitPayOrder(PayOrderVo payOrderVo) throws CustomException, ParseException;
	
	public Result deleteToPay(Long payId, Result res) throws CustomException;
	
	public PayOrder findPayOrderById(Long id);
	
	public Result updatePayState(String payNo, String cashFee, String result, String payMethod);
	
	public void savePayLog(String payMethod, BigDecimal realPay, Long payId, String remark, String backParameter);
	
	public Long getPayId(String payNo);
	
	public boolean preholdCisStock(List<OrderDetail> orderDetail, int flag, OrderInfo orderInfo, String remark, String worker, Short isALLRelease);
	
	/** 
	 *
	 * @Title: getUseDiscountAmount 
	 * @author: wuyicheng
	 * @date: 2017年6月20日下午6:30:12 
	 * @param subtotal
	 * @param proTotalAmount
	 * @param discountAmount
	 * @return
	 * @return: BigDecimal
	 * @throws 
	 */
	public BigDecimal getUseDiscountAmount(BigDecimal subtotal, BigDecimal proTotalAmount, BigDecimal discountAmount);
	
	public ModityOrderUseStore modityOrderStoreValue(String orderNo, Long sysId, Long memberId, BigDecimal useStoreValue) throws CustomException;
}
